package com.ys.erp.entity.service.impl;

import cn.hutool.core.util.ObjectUtil;
import com.baomidou.mybatisplus.core.conditions.query.QueryWrapper;
import com.baomidou.mybatisplus.extension.service.impl.ServiceImpl;

import com.ys.erp.entity.data.bean.CatCage;
import com.ys.erp.entity.mapper.CatCageMapper;
import com.ys.erp.entity.service.ICatCageService;
import org.springframework.stereotype.Service;

import java.util.ArrayList;
import java.util.Collection;
import java.util.List;

/**
 * @author lwj
 * @date 2024/1/5
 */
    
@Service
public class ICatCageServiceImpl extends ServiceImpl<CatCageMapper, CatCage> implements ICatCageService {

    @Override
    public List<CatCage> listCageByNos(Collection<String> noList) {
        if (ObjectUtil.isEmpty(noList) || noList.isEmpty()) {
            return new ArrayList<>();
        }
        QueryWrapper<CatCage> cageQw = new QueryWrapper<>();
        cageQw.lambda().in(CatCage::getCageNo, noList);
        return this.list(cageQw);
    }

}
